| Conditions | 1 |
| Total Lines | 7 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | import {MigrationInterface, QueryRunner} from "typeorm"; |
||
| 13 | |||
| 14 | public async down(queryRunner: QueryRunner): Promise<void> { |
||
| 15 | await queryRunner.query(`ALTER TABLE "photo" DROP CONSTRAINT "FK_b30092abccf18923f482de41f38"`); |
||
| 16 | await queryRunner.query(`ALTER TABLE "classroom" DROP CONSTRAINT "FK_43477ae183519f09a40c2fd1250"`); |
||
| 17 | await queryRunner.query(`DROP TABLE "classroom"`); |
||
| 18 | await queryRunner.query(`ALTER TABLE "photo" RENAME COLUMN "classroomId" TO "shootingId"`); |
||
| 19 | await queryRunner.query(`ALTER TABLE "photo" ADD CONSTRAINT "FK_e4a158e221f64fd303021454b51" FOREIGN KEY ("shootingId") REFERENCES "shooting"("id") ON DELETE CASCADE ON UPDATE NO ACTION`); |
||
| 20 | } |
||
| 23 |